package com.spring.oaassist.web.model;

import java.io.Serializable;

import javax.validation.constraints.Digits;

import org.hibernate.validator.constraints.NotEmpty;

import com.spring.security.core.validators.Delete;
import com.spring.security.core.validators.Insert;
import com.spring.security.core.validators.Receive;
import com.spring.security.core.validators.Update;

public class Task implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	@NotEmpty(message = "任务编号不可为空",groups = {Update.class,Delete.class,Receive.class})
	private String id;
	@NotEmpty(message = "任务标题不可为空",groups = {Insert.class})
	private String title;
	private String plan_month_detailID;
	private String plan_month_detailName;
	@NotEmpty(message = "任务开始时间不可为空",groups = {Insert.class})
	private String beginTime;
	@NotEmpty(message = "任务结束时间不可为空",groups = {Insert.class})
	private String endTime;
	@NotEmpty(message = "所需时间不可为空",groups = {Insert.class})
	@Digits(integer=2,fraction=1,message = "所需时间格式必须为:XX.X",groups = {Insert.class})
	private String needTime;
	@NotEmpty(message = "任务标准不可为空",groups = {Insert.class})
	private String standard;
	@NotEmpty(message = "任务目标不可为空",groups = {Insert.class})
	private String goal;
	@NotEmpty(message = "责任人不可为空",groups = {Insert.class})
	private String ownerID;
	@NotEmpty(message = "责任人不可为空",groups = {Insert.class,Receive.class})
	private String ownerName;
	@NotEmpty(message = "责任部门不可为空",groups = {Insert.class,Receive.class})
	private String ownerDeptID;
	@NotEmpty(message = "责任部门不可为空",groups = {Insert.class})
	private String ownerDeptName;
	@NotEmpty(message = "优先级不可为空",groups = {Insert.class})
	private String priority_typeCode;
	@NotEmpty(message = "变更频率不可为空",groups = {Insert.class})
	@Digits(integer=2,fraction=1,message = "变更频率格式必须为:XX.X",groups = {Insert.class})
	private String frequency;
	@NotEmpty(message = "完成百分比不可为空",groups = {Insert.class,Update.class})
	//@Pattern(regexp = "^[0-9]*$", message = "完成度必须为数字",groups = {Insert.class,Update.class})  
	@Digits(integer=1,fraction=2,message = "完成百分比格式必须为:X.XX",groups = {Insert.class,Update.class})
	private String completeRatio;
	private String parentId;
	private String parentTaskName;
	@NotEmpty(message = "任务状态不可为空",groups = {Update.class})
	private String task_statusCode;
	private String applyDeptID;
	private String applyDeptName;
	private String applyUserID;
	private String applyUserName;
	
	private String acceptStatusCode = "0";
	//@NotEmpty(message = "拒绝理由",groups = {Delete.class})
	private String refuseReason;
	
	private String EntityAvailableState;
	private String OperatorID;
	private String OperatorName;
	private String note;
	private String marketingBudget;//营销目标
	private String marketingPlanOrEvaluation;//富文本简介
	@NotEmpty(message = "任务类型不可为空",groups = {Insert.class})
	private String plan_typeID;//任务类型
	
	private String planTypeName;
	
	public String getPlanTypeName() {
		return planTypeName;
	}
	public void setPlanTypeName(String planTypeName) {
		this.planTypeName = planTypeName;
	}
	public String getMarketingBudget() {
		return marketingBudget;
	}
	public void setMarketingBudget(String marketingBudget) {
		this.marketingBudget = marketingBudget;
	}
	public String getMarketingPlanOrEvaluation() {
		return marketingPlanOrEvaluation;
	}
	public void setMarketingPlanOrEvaluation(String marketingPlanOrEvaluation) {
		this.marketingPlanOrEvaluation = marketingPlanOrEvaluation;
	}
	public String getPlan_typeID() {
		return plan_typeID;
	}
	public void setPlan_typeID(String plan_typeID) {
		this.plan_typeID = plan_typeID;
	}
	public String getNote() {
		return note;
	}
	public void setNote(String note) {
		this.note = note;
	}
	public String getOperatorID() {
		return OperatorID;
	}
	public void setOperatorID(String operatorID) {
		OperatorID = operatorID;
	}
	public String getOperatorName() {
		return OperatorName;
	}
	public void setOperatorName(String operatorName) {
		OperatorName = operatorName;
	}
	public String getGoal() {
		return goal;
	}
	public void setGoal(String goal) {
		this.goal = goal;
	}
	public String getParentTaskName() {
		return parentTaskName;
	}
	public void setParentTaskName(String parentTaskName) {
		this.parentTaskName = parentTaskName;
	}
	public String getEntityAvailableState() {
		return EntityAvailableState;
	}
	public void setEntityAvailableState(String entityAvailableState) {
		EntityAvailableState = entityAvailableState;
	}
	public String getPlan_month_detailName() {
		return plan_month_detailName;
	}
	public void setPlan_month_detailName(String plan_month_detailName) {
		this.plan_month_detailName = plan_month_detailName;
	}
	public String getAcceptStatusCode() {
		return acceptStatusCode;
	}
	public void setAcceptStatusCode(String acceptStatusCode) {
		this.acceptStatusCode = acceptStatusCode;
	}
	public String getRefuseReason() {
		return refuseReason;
	}
	public void setRefuseReason(String refuseReason) {
		this.refuseReason = refuseReason;
	}
	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	public String getPlan_month_detailID() {
		return plan_month_detailID;
	}
	public void setPlan_month_detailID(String plan_month_detailID) {
		this.plan_month_detailID = plan_month_detailID;
	}
	public String getBeginTime() {
		return beginTime;
	}
	public void setBeginTime(String beginTime) {
		this.beginTime = beginTime;
	}
	public String getEndTime() {
		return endTime;
	}
	public void setEndTime(String endTime) {
		this.endTime = endTime;
	}
	public String getNeedTime() {
		return needTime;
	}
	public void setNeedTime(String needTime) {
		this.needTime = needTime;
	}
	public String getStandard() {
		return standard;
	}
	public void setStandard(String standard) {
		this.standard = standard;
	}
	public String getOwnerID() {
		return ownerID;
	}
	public void setOwnerID(String ownerID) {
		this.ownerID = ownerID;
	}
	public String getOwnerName() {
		return ownerName;
	}
	public void setOwnerName(String ownerName) {
		this.ownerName = ownerName;
	}
	public String getOwnerDeptID() {
		return ownerDeptID;
	}
	public void setOwnerDeptID(String ownerDeptID) {
		this.ownerDeptID = ownerDeptID;
	}
	public String getOwnerDeptName() {
		return ownerDeptName;
	}
	public void setOwnerDeptName(String ownerDeptName) {
		this.ownerDeptName = ownerDeptName;
	}
	public String getPriority_typeCode() {
		return priority_typeCode;
	}
	public void setPriority_typeCode(String priority_typeCode) {
		this.priority_typeCode = priority_typeCode;
	}
	public String getFrequency() {
		return frequency;
	}
	public void setFrequency(String frequency) {
		this.frequency = frequency;
	}
	public String getCompleteRatio() {
		return completeRatio;
	}
	public void setCompleteRatio(String completeRatio) {
		this.completeRatio = completeRatio;
	}
	public String getParentId() {
		return parentId;
	}
	public void setParentId(String parentId) {
		this.parentId = parentId;
	}
	public String getTask_statusCode() {
		return task_statusCode;
	}
	public void setTask_statusCode(String task_statusCode) {
		this.task_statusCode = task_statusCode;
	}
	public String getApplyDeptID() {
		return applyDeptID;
	}
	public void setApplyDeptID(String applyDeptID) {
		this.applyDeptID = applyDeptID;
	}
	public String getApplyDeptName() {
		return applyDeptName;
	}
	public void setApplyDeptName(String applyDeptName) {
		this.applyDeptName = applyDeptName;
	}
	public String getApplyUserID() {
		return applyUserID;
	}
	public void setApplyUserID(String applyUserID) {
		this.applyUserID = applyUserID;
	}
	public String getApplyUserName() {
		return applyUserName;
	}
	public void setApplyUserName(String applyUserName) {
		this.applyUserName = applyUserName;
	}

}
